x86: optimize introspection access to guest state
authorRazvan Cojocaru <rcojocaru@bitdefender.com>
Thu, 18 Sep 2014 12:54:58 +0000 (14:54 +0200)
committerJan Beulich <jbeulich@suse.com>
Thu, 18 Sep 2014 12:54:58 +0000 (14:54 +0200)
commit9eb81d8bcb393fd2280bc6bc2d36fafa251fd9c0
tree5036ab10895f83faaca1360066c1d448b6014450
parent4ae69fc45c815c32ae0fd6edb2bc159fd9d8a559
x86: optimize introspection access to guest state

Speed optimization for introspection purposes: a handful of registers
are sent along with each mem_event. This requires enlargement of the
mem_event_request / mem_event_response stuctures, and additional code
to fill in relevant values. Since the EPT event processing code needs
more data than CR3 or MSR event processors, hvm_mem_event_fill_regs()
fills in less data than p2m_mem_event_fill_regs(), in order to avoid
overhead. Struct hvm_hw_cpu has been considered instead of the custom
struct mem_event_regs_st, but its size would cause quick filling up
of the mem_event ring buffer.

Signed-off-by: Razvan Cojocaru <rcojocaru@bitdefender.com>
Acked-by: Jan Beulich <jbeulich@suse.com>
Acked-by: Tim Deegan <tim@xen.org>
xen/arch/x86/hvm/hvm.c
xen/arch/x86/mm/p2m.c
xen/include/public/mem_event.h